namespace Traceability.API.Models
{
    /// <summary>
    /// 七牛云上传响应模型
    /// </summary>
    public class QiNiuUploadResponse
    {
        /// <summary>
        /// 是否成功
        /// </summary>
        public bool Success { get; set; }

        /// <summary>
        /// 消息
        /// </summary>
        public string Message { get; set; } = string.Empty;

        /// <summary>
        /// 文件访问URL
        /// </summary>
        public string Url { get; set; } = string.Empty;

        /// <summary>
        /// 文件Key
        /// </summary>
        public string Key { get; set; } = string.Empty;

        /// <summary>
        /// 文件大小(字节)
        /// </summary>
        public long Size { get; set; }

        /// <summary>
        /// 文件类型
        /// </summary>
        public string ContentType { get; set; } = string.Empty;

        /// <summary>
        /// 上传时间
        /// </summary>
        public DateTime UploadTime { get; set; } = DateTime.Now;
    }

    /// <summary>
    /// 七牛云删除响应模型
    /// </summary>
    public class QiNiuDeleteResponse
    {
        /// <summary>
        /// 是否成功
        /// </summary>
        public bool Success { get; set; }

        /// <summary>
        /// 消息
        /// </summary>
        public string Message { get; set; } = string.Empty;

        /// <summary>
        /// 删除的文件Key
        /// </summary>
        public string Key { get; set; } = string.Empty;
    }

    /// <summary>
    /// 七牛云上传Token响应模型
    /// </summary>
    public class QiNiuTokenResponse
    {
        /// <summary>
        /// 上传Token
        /// </summary>
        public string Token { get; set; } = string.Empty;

        /// <summary>
        /// Token过期时间
        /// </summary>
        public DateTime ExpireTime { get; set; }

        /// <summary>
        /// 上传域名
        /// </summary>
        public string UploadUrl { get; set; } = string.Empty;
    }

    /// <summary>
    /// 文件信息模型
    /// </summary>
    public class FileInfo
    {
        /// <summary>
        /// 文件名
        /// </summary>
        public string FileName { get; set; } = string.Empty;

        /// <summary>
        /// 文件大小
        /// </summary>
        public long Size { get; set; }

        /// <summary>
        /// 文件类型
        /// </summary>
        public string ContentType { get; set; } = string.Empty;

        /// <summary>
        /// 文件扩展名
        /// </summary>
        public string Extension { get; set; } = string.Empty;
    }
}
